package com.firewolf.spring.service.proxy;

import com.firewolf.spring.service.ICalucator;

/**
  使用代理处理日志功能，计算器只管计算数据就好了
 * @author lx
 *
 */
public class Calculator2 implements ICalucator {

	@Override
	public double add(double i, double j) {
		double result = i + j;
		System.out.println(result);
		return result;
	}

	@Override
	public double sub(double i, double j) {
		double result = i - j;
		System.out.println(result);
		return result;
	}

	@Override
	public double multi(double i, double j) {
		double result = i * j;
		System.out.println(result);
		return result;
	}

	@Override
	public double dev(double i, double j) {
		double result = i / j;
		System.out.println(result);
		return result;
	}

}
